<!DOCTYPE html>
<html lang="en-US">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>golay_elements [HALCON算子参考手册]</title>
<style type="text/css">
      body {
    color: #000000;
    background-color: #ffffff;
    margin: 0;
    font-family: Arial, Helvetica, sans-serif;
}

.body_main {
    margin-left: 35px;
    margin-right: 35px;
}

@media screen and (min-width:992px) {

    .body_main {
        margin-left: 10%;
        margin-right: 10%;
    }

    table.toctable {
        width: 80%
    }
}

@media screen and (min-width:1400px) {

    .body_main {
        margin-left: 15%;
        margin-right: 15%;
    }

    table.toctable {
        width: 70%
    }
}

body>div ul ul {
    margin-left: inherit;
}

a:link {
    color: #0044cc;
}

a:link,
a:visited {
    text-decoration: none;
}

a:link:hover,
a:visited:hover {
    text-decoration: underline;
}

th {
    text-align: left;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    text-rendering: optimizeLegibility;
    color: #666666;
}

code {
    font-family: monospace,monospace;
}

h1 a.halconoperator {
    font-family: Arial, Helvetica, sans-serif;
    color: #666666;
}

h2 a.halconoperator {
    font-family: Arial, Helvetica, sans-serif;
    color: #666666;
}

hr {
    border: 0;
    border-top: solid 1px #f28d26;
}

.pre {
    display: block;
    padding-bottom: 1ex;
    font-family: monospace;
    white-space: pre;
}

pre {
    font-family: monospace, monospace;
    padding: 1ex;
    white-space: pre-wrap;
}

.toc {
    font-size: 80%;
    border-top: 1px dashed #f28d26;
    border-bottom: 1px dashed #f28d26;
    padding-top: 5px;
    padding-bottom: 5px;
}

.inv {
    margin: 0;
    border: 0;
    padding: 0;
}

.banner {
    color: #666666;
    padding-left: 1em;
}

.logo {
    background-color: white;
}

.keyboard {
    font-size: 80%;
    padding-left: 3px;
    padding-right: 3px;
    border-radius: 5px;
    border-width: 1px;
    border-style: solid;
    border-color: #f28d26;
    background-color: #f3f3f3;
}

.warning {
    margin-top: 2ex;
    margin-bottom: 1ex;
    padding: 10px;
    text-align: center;
    border: 1px solid;
    color: #bb0000;
    background-color: #fff7f7
}

.imprint {
    margin-top: 1ex;
    font-size: 80%;
    color: #666666;
}

.imprinthead {
    font-weight: bolder;
    color: #666666;
}

.indexlink {
    text-align: right;
    padding-bottom: 5px;
}

.postscript {
    margin-top: 2ex;
    font-size: 80%;
    color: #666666
}

.evenrow {
    background-color: #e7e7ef;
    vertical-align: top;
}

.oddrow {
    background-color: #f7f7ff;
    vertical-align: top;
}

.headrow {
    background-color: #97979f;
    color: #ffffff;
    vertical-align: top;
}

.logorow {
    vertical-align: top;
}

.error {
    color: red;
}

.var {
    font-style: italic
}

.halconoperator {
    font-family: monospace, monospace;
}

span.operator {
    font-family: monospace, monospace;
}

span.procedure {
    font-family: monospace, monospace;
}

span.operation {
    font-family: monospace, monospace;
}

span.feature {
    font-family: Arial, Helvetica, Homerton, sans-serif;
}

ul {
    padding-left: 1.2em;
}

li.dot {
    list-style-type: square;
    color: #f28d26;
}

.breadcrumb {
    font-size: 80%;
    color: white;
    background-color: #062d64;
    margin-bottom: 20px;
    padding-left: 35px;
    padding-right: 35px;
    padding-bottom: 15px;
}

.webbar {
    font-size: 80%;
    background-color: #dddddd;
    margin-top: 0px;
    margin-left: -35px;
    margin-right: -35px;
    margin-bottom: 0px;
    padding-top: 5px;
    padding-left: 35px;
    padding-right: 35px;
    padding-bottom: 5px;
}

.footer {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    border-top: 1px dashed #f28d26;
    font-size: 80%;
    color: #666666;
    padding-bottom: 8px;
}

.footer .socialmedia a {
    padding-left: 7px;
}

.socialmedia {
    padding-top: 10px;
}

.copyright {
    margin-top: 19px;
}

.breadcrumb a {
    color: #ffffff;
    border-bottom: 1px solid white;
}

.breadcrumb a:link:hover,
.breadcrumb a:visited:hover {
    text-decoration: none;
    border-bottom: none;
}

.heading {
    margin-top: 1ex;
    font-size: 110%;
    font-weight: bold;
    color: #666666;
}

.text {
    color: black;
}

.example {
    font-size: 80%;
    background-color: #f3f3f3;
    border: 1px dashed #666666;
    padding: 10px;
}

.displaymath {
    display: block;
    text-align: center;
    margin-top: 1ex;
    margin-bottom: 1ex;
}

.title {
    float: left;
    padding-top: 3px;
    padding-bottom: 3px;
}

.signnote {
    font-family: Arial, Helvetica, Homerton, sans-serif;
    font-size: 80%;
    color: #666666;
    font-weight: lighter;
    font-style: italic
}

.par {
    margin-bottom: 1.5em;
}

.parhead {
    text-align: right;
}

.parname {
    float: left;
}

.pardesc {
    font-size: 85%;
    margin-top: 0.5em;
    margin-bottom: 0.5em;
    margin-left: 2em;
}

.parcat {
    color: #666;
    font-weight: bold;
}

*[data-if=cpp],
*[data-if=c],
*[data-if=dotnet],
*[data-if=com],
*[data-if=python] {
    display: none;
}

.tabbar {
    text-align: right;
    border-bottom: 1px solid #f28d26;
    margin-bottom: 0.5em;
}

ul.tabs {
    padding-top: 3px;
    padding-bottom: 3px;
    margin-top: 10px;
    margin-bottom: 0;
    font-size: 80%
}

ul.tabs li {
    padding-top: 3px;
    padding-bottom: 3px;
    display: inline;
    overflow: hidden;
    list-style-type: none;
    margin: 0;
    margin-left: 8px;
    border-top: 1px solid #666;
    border-left: 1px solid #666;
    border-right: 1px solid #666;
}

ul.tabs li.active {
    border-left: 1px solid #f28d26;
    border-right: 1px solid #f28d26;
    border-top: 1px solid #f28d26;
    border-bottom: 1px solid #fff;
}

ul.tabs li.inactive {
    background-color: #eee;
}

ul.tabs li a {
    padding-left: 5px;
    padding-right: 5px;
    color: #666;
}

ul.tabs li a:link:hover {
    text-decoration: none;
}

ul.tabs li.inactive a {
    color: #666;
}

ul.tabs li.active a {
    color: black;
}

dl.generic dd {
    margin-bottom: 1em;
}

.pari {
    color: olive;
}

.paro {
    color: maroon;
}

.comment {
    font-size: 80%;
    color: green;
    white-space: nowrap;
}

table.grid {
    border-collapse: collapse;
}

table.grid td {
    padding: 5px;
    border: 1px solid;
}

table.layout {
    border: 0px;
}

table.layout td {
    padding: 5px;
}

table.table {
    border-collapse: collapse;
}

table.table td {
    padding: 5px;
    border-left: 0px;
    border-right: 0px;
}

table.table tr:last-child {
    border-bottom: 1px solid;
}

table.table th {
    padding: 5px;
    border-top: 1px solid;
    border-bottom: 1px solid;
    border-left: 0px;
    border-right: 0px;
}

.details_summary {
    cursor: pointer;
}

table.toctable {
    width: 100%;
}

table.toctable col:first-child {
    width: 20%;
}

table.toctable col:nth-last-child(2) {
    width: 8%;
}

table.altcolored tr:nth-child(even) {
    background-color: #f3f3f3;
}

    </style>
<!--OP_REF_STYLE_END-->
<script>
    <!--
var active_lang='hdevelop';function switchVisibility(obj,active_lang,new_lang)
{var display_style='inline';
for(var i=0;i<obj.length;i++)
{if(obj.item(i).getAttribute('data-if')==new_lang)
{obj.item(i).style.display=display_style;}
if(obj.item(i).getAttribute('data-if')==active_lang)
{obj.item(i).style.display='none';}}
return;}
function toggleLanguage(new_lang,initial)
{if(active_lang!=new_lang)
{var lis=document.getElementsByTagName('li');for(var i=0;i<lis.length;i++)
{if(lis.item(i).id=='syn-'+new_lang)
{lis.item(i).className='active';}
else
{lis.item(i).className='inactive';}}
var divs=document.getElementsByTagName('div');var spans=document.getElementsByTagName('span');switchVisibility(divs,active_lang,new_lang);switchVisibility(spans,active_lang,new_lang);if(!initial)
{setCookie("halcon_reference_language",new_lang,null,null);}
active_lang=new_lang;}
return;}
function setCookie(name,value,domain,exp_offset,path,secure)
{localStorage.setItem(name,value);}
function getCookie(name)
{return localStorage.getItem(name);}
function initialize()
{var qs=location.href.split('?')[1];var qs_lang_raw=location.href.split('interface=')[1];var qs_lang;if(qs_lang_raw)
{qs_lang=qs_lang_raw.split('#')[0];}
var cookie_lang=getCookie("halcon_reference_language");var new_lang;if((qs_lang=="hdevelop")||(qs_lang=="dotnet")||(qs_lang=="python")||(qs_lang=="cpp")||(qs_lang=="c"))
{new_lang=qs_lang;setCookie("halcon_reference_language",new_lang,null,null);}
else if((cookie_lang=="hdevelop")||(cookie_lang=="dotnet")||(cookie_lang=="python")||(cookie_lang=="cpp")||(cookie_lang=="c"))
{new_lang=cookie_lang;}
else
{new_lang="hdevelop";}
toggleLanguage(new_lang,1);return;}
-->

  </script>
</head>
<body onload="initialize();">
<div class="breadcrumb">
<br class="inv"><a href="index.html">目录</a> / <a href="toc_legacy.html">过时</a> / <a href="toc_legacy_morphology.html">形态学</a><br class="inv">
</div>
<div class="body_main">
<div class="tabbar"><ul class="tabs">
<li id="syn-hdevelop" class="active"><a href="javascript:void(0);" onclick="toggleLanguage('hdevelop')" onfocus="blur()">HDevelop</a></li>
<li id="syn-dotnet" class="inactive"><a href="javascript:void(0);" onclick="toggleLanguage('dotnet')" onfocus="blur()">.NET</a></li>
<li id="syn-python" class="inactive"><a href="javascript:void(0);" onclick="toggleLanguage('python')" onfocus="blur()">Python</a></li>
<li id="syn-cpp" class="inactive"><a href="javascript:void(0);" onclick="toggleLanguage('cpp')" onfocus="blur()">C++</a></li>
<li id="syn-c" class="inactive"><a href="javascript:void(0);" onclick="toggleLanguage('c')" onfocus="blur()">C</a></li>
</ul></div>
<div class="indexlink">
<a href="index_classes.html"><span data-if="dotnet" style="display:none;">类别</span><span data-if="cpp" style="display:none;">类别</span></a><span data-if="dotnet" style="display:none;"> | </span><span data-if="cpp" style="display:none;"> | </span><a href="index_by_name.html">算子列表</a>
</div>
<!--OP_REF_HEADER_END-->
<h1 id="sec_name">
<span data-if="hdevelop" style="display:inline;">golay_elements</span><span data-if="c" style="display:none;">golay_elements</span><span data-if="cpp" style="display:none;">GolayElements</span><span data-if="dotnet" style="display:none;">GolayElements</span><span data-if="python" style="display:none;">golay_elements</span> (算子名称)</h1>
<h2>名称</h2>
<p><code><span data-if="hdevelop" style="display:inline;">golay_elements</span><span data-if="c" style="display:none;">golay_elements</span><span data-if="cpp" style="display:none;">GolayElements</span><span data-if="dotnet" style="display:none;">GolayElements</span><span data-if="python" style="display:none;">golay_elements</span></code> — Generate the structuring elements of the Golay alphabet.</p>
<h2>警告</h2>
<p><b><code><span data-if="hdevelop" style="display:inline">golay_elements</span><span data-if="c" style="display:none">golay_elements</span><span data-if="cpp" style="display:none">GolayElements</span><span data-if="com" style="display:none">GolayElements</span><span data-if="dotnet" style="display:none">GolayElements</span><span data-if="python" style="display:none">golay_elements</span></code> is obsolete and is only provided for
reasons of backward compatibility.</b></p>
<h2 id="sec_synopsis">参数签名</h2>
<div data-if="hdevelop" style="display:inline;">
<p>
<code><b>golay_elements</b>( : <a href="#StructElement1"><i>StructElement1</i></a>, <a href="#StructElement2"><i>StructElement2</i></a> : <a href="#GolayElement"><i>GolayElement</i></a>, <a href="#Rotation"><i>Rotation</i></a>, <a href="#Row"><i>Row</i></a>, <a href="#Column"><i>Column</i></a> : )</code></p>
</div>
<div data-if="c" style="display:none;">
<p>
<code>Herror <b>golay_elements</b>(Hobject* <a href="#StructElement1"><i>StructElement1</i></a>, Hobject* <a href="#StructElement2"><i>StructElement2</i></a>, const char* <a href="#GolayElement"><i>GolayElement</i></a>, const Hlong <a href="#Rotation"><i>Rotation</i></a>, const Hlong <a href="#Row"><i>Row</i></a>, const Hlong <a href="#Column"><i>Column</i></a>)</code></p>
<p>
<code>Herror <b>T_golay_elements</b>(Hobject* <a href="#StructElement1"><i>StructElement1</i></a>, Hobject* <a href="#StructElement2"><i>StructElement2</i></a>, const Htuple <a href="#GolayElement"><i>GolayElement</i></a>, const Htuple <a href="#Rotation"><i>Rotation</i></a>, const Htuple <a href="#Row"><i>Row</i></a>, const Htuple <a href="#Column"><i>Column</i></a>)</code></p>
</div>
<div data-if="cpp" style="display:none;">
<p>
<code>void <b>GolayElements</b>(HObject* <a href="#StructElement1"><i>StructElement1</i></a>, HObject* <a href="#StructElement2"><i>StructElement2</i></a>, const HTuple&amp; <a href="#GolayElement"><i>GolayElement</i></a>, const HTuple&amp; <a href="#Rotation"><i>Rotation</i></a>, const HTuple&amp; <a href="#Row"><i>Row</i></a>, const HTuple&amp; <a href="#Column"><i>Column</i></a>)</code></p>
<p>
<code><a href="HRegion.html">HRegion</a> <a href="HRegion.html">HRegion</a>::<b>GolayElements</b>(const HString&amp; <a href="#GolayElement"><i>GolayElement</i></a>, Hlong <a href="#Rotation"><i>Rotation</i></a>, Hlong <a href="#Row"><i>Row</i></a>, Hlong <a href="#Column"><i>Column</i></a>)</code></p>
<p>
<code><a href="HRegion.html">HRegion</a> <a href="HRegion.html">HRegion</a>::<b>GolayElements</b>(const char* <a href="#GolayElement"><i>GolayElement</i></a>, Hlong <a href="#Rotation"><i>Rotation</i></a>, Hlong <a href="#Row"><i>Row</i></a>, Hlong <a href="#Column"><i>Column</i></a>)</code></p>
<p>
<code><a href="HRegion.html">HRegion</a> <a href="HRegion.html">HRegion</a>::<b>GolayElements</b>(const wchar_t* <a href="#GolayElement"><i>GolayElement</i></a>, Hlong <a href="#Rotation"><i>Rotation</i></a>, Hlong <a href="#Row"><i>Row</i></a>, Hlong <a href="#Column"><i>Column</i></a>)  <span class="signnote">
            (
            Windows only)
          </span></code></p>
</div>
<div data-if="com" style="display:none;"></div>
<div data-if="dotnet" style="display:none;">
<p>
<code>static void <a href="HOperatorSet.html">HOperatorSet</a>.<b>GolayElements</b>(out <a href="HObject.html">HObject</a> <a href="#StructElement1"><i>structElement1</i></a>, out <a href="HObject.html">HObject</a> <a href="#StructElement2"><i>structElement2</i></a>, <a href="HTuple.html">HTuple</a> <a href="#GolayElement"><i>golayElement</i></a>, <a href="HTuple.html">HTuple</a> <a href="#Rotation"><i>rotation</i></a>, <a href="HTuple.html">HTuple</a> <a href="#Row"><i>row</i></a>, <a href="HTuple.html">HTuple</a> <a href="#Column"><i>column</i></a>)</code></p>
<p>
<code><a href="HRegion.html">HRegion</a> <a href="HRegion.html">HRegion</a>.<b>GolayElements</b>(string <a href="#GolayElement"><i>golayElement</i></a>, int <a href="#Rotation"><i>rotation</i></a>, int <a href="#Row"><i>row</i></a>, int <a href="#Column"><i>column</i></a>)</code></p>
</div>
<div data-if="python" style="display:none;">
<p>
<code>def <b>golay_elements</b>(<a href="#GolayElement"><i>golay_element</i></a>: str, <a href="#Rotation"><i>rotation</i></a>: int, <a href="#Row"><i>row</i></a>: int, <a href="#Column"><i>column</i></a>: int) -&gt; Tuple[HObject, HObject]</code></p>
</div>
<h2 id="sec_description">描述</h2>
<p><code><span data-if="hdevelop" style="display:inline">golay_elements</span><span data-if="c" style="display:none">golay_elements</span><span data-if="cpp" style="display:none">GolayElements</span><span data-if="com" style="display:none">GolayElements</span><span data-if="dotnet" style="display:none">GolayElements</span><span data-if="python" style="display:none">golay_elements</span></code> generates the structuring elements from
the Golay alphabet.  The parameter <a href="#GolayElement"><i><code><span data-if="hdevelop" style="display:inline">GolayElement</span><span data-if="c" style="display:none">GolayElement</span><span data-if="cpp" style="display:none">GolayElement</span><span data-if="com" style="display:none">GolayElement</span><span data-if="dotnet" style="display:none">golayElement</span><span data-if="python" style="display:none">golay_element</span></code></i></a>
determines the name of the structuring element, while
<a href="#Rotation"><i><code><span data-if="hdevelop" style="display:inline">Rotation</span><span data-if="c" style="display:none">Rotation</span><span data-if="cpp" style="display:none">Rotation</span><span data-if="com" style="display:none">Rotation</span><span data-if="dotnet" style="display:none">rotation</span><span data-if="python" style="display:none">rotation</span></code></i></a> determines its rotation.  The structuring
elements are intended for use in <a href="hit_or_miss.html"><code><span data-if="hdevelop" style="display:inline">hit_or_miss</span><span data-if="c" style="display:none">hit_or_miss</span><span data-if="cpp" style="display:none">HitOrMiss</span><span data-if="com" style="display:none">HitOrMiss</span><span data-if="dotnet" style="display:none">HitOrMiss</span><span data-if="python" style="display:none">hit_or_miss</span></code></a>: In
<a href="#StructElement1"><i><code><span data-if="hdevelop" style="display:inline">StructElement1</span><span data-if="c" style="display:none">StructElement1</span><span data-if="cpp" style="display:none">StructElement1</span><span data-if="com" style="display:none">StructElement1</span><span data-if="dotnet" style="display:none">structElement1</span><span data-if="python" style="display:none">struct_element_1</span></code></i></a> the structuring element for the foreground
is returned, while in <a href="#StructElement2"><i><code><span data-if="hdevelop" style="display:inline">StructElement2</span><span data-if="c" style="display:none">StructElement2</span><span data-if="cpp" style="display:none">StructElement2</span><span data-if="com" style="display:none">StructElement2</span><span data-if="dotnet" style="display:none">structElement2</span><span data-if="python" style="display:none">struct_element_2</span></code></i></a> the structuring
element for the background is returned.  <a href="#Row"><i><code><span data-if="hdevelop" style="display:inline">Row</span><span data-if="c" style="display:none">Row</span><span data-if="cpp" style="display:none">Row</span><span data-if="com" style="display:none">Row</span><span data-if="dotnet" style="display:none">row</span><span data-if="python" style="display:none">row</span></code></i></a> and
<a href="#Column"><i><code><span data-if="hdevelop" style="display:inline">Column</span><span data-if="c" style="display:none">Column</span><span data-if="cpp" style="display:none">Column</span><span data-if="com" style="display:none">Column</span><span data-if="dotnet" style="display:none">column</span><span data-if="python" style="display:none">column</span></code></i></a> determine the reference point of the structuring
element.
</p>
<p>The rotations are numbered from 0 to 15.  This does not mean,
however, that there are 16 different rotations: Even values denote
rotations of the foreground elements, while odd values denote
rotations of the background elements.
</p>
<p>For <code><span data-if="hdevelop" style="display:inline">golay_elements</span><span data-if="c" style="display:none">golay_elements</span><span data-if="cpp" style="display:none">GolayElements</span><span data-if="com" style="display:none">GolayElements</span><span data-if="dotnet" style="display:none">GolayElements</span><span data-if="python" style="display:none">golay_elements</span></code> only even values are accepted, and
determine the Golay element for <a href="#StructElement1"><i><code><span data-if="hdevelop" style="display:inline">StructElement1</span><span data-if="c" style="display:none">StructElement1</span><span data-if="cpp" style="display:none">StructElement1</span><span data-if="com" style="display:none">StructElement1</span><span data-if="dotnet" style="display:none">structElement1</span><span data-if="python" style="display:none">struct_element_1</span></code></i></a>.  The next
larger odd value is used for <a href="#StructElement2"><i><code><span data-if="hdevelop" style="display:inline">StructElement2</span><span data-if="c" style="display:none">StructElement2</span><span data-if="cpp" style="display:none">StructElement2</span><span data-if="com" style="display:none">StructElement2</span><span data-if="dotnet" style="display:none">structElement2</span><span data-if="python" style="display:none">struct_element_2</span></code></i></a>.  There are
no rotations for the Golay elements 'h' and 'i'.  Therefore, only
the values 0 and 1 are possible as “rotations” (and hence only 0
for <code><span data-if="hdevelop" style="display:inline">golay_elements</span><span data-if="c" style="display:none">golay_elements</span><span data-if="cpp" style="display:none">GolayElements</span><span data-if="com" style="display:none">GolayElements</span><span data-if="dotnet" style="display:none">GolayElements</span><span data-if="python" style="display:none">golay_elements</span></code>).  The element 'e' has only four
possible rotations, and hence the rotation must be between 0 and 7
(for <code><span data-if="hdevelop" style="display:inline">golay_elements</span><span data-if="c" style="display:none">golay_elements</span><span data-if="cpp" style="display:none">GolayElements</span><span data-if="com" style="display:none">GolayElements</span><span data-if="dotnet" style="display:none">GolayElements</span><span data-if="python" style="display:none">golay_elements</span></code> the values 0, 2, 4, or 6 must be
used).
</p>
<p>The tables below show the elements of the Golay alphabet with all
possible rotations.  The characters used have the following meaning:
<span class="pre">
  *  Foreground pixel
  o  Background pixel
  .  Don't care pixel
</span>
The names of the elements and their rotation numbers are displayed
below the respective element.  The elements with even number contain
the foreground pixels, while the elements with odd numbers contain
the background pixels.
<span class="pre">
  * * *
  * * *
  * * *
  h(0,1)

  o o o
  o o o
  o o o
  i(0,1)

  . . .    o o .    o o o    . o o
  o * o    o * .    o * o    . * o
  o o o    o o .    . . .    . o o
  e(0,1)   e(2,3)   e(4,5)   e(6,7)

             o                 *                 *                  o
  o o o    . . o    * . o    * . .    * * *    . . *    o . *     o . .
  . * .  * . * . o  * * o  * . * . o  . * .  o . * . *  o * *   o . *   *
  * * *    * . .    * . o    . . o    o o o    o . .    o . *     . . *
             *                 o                 o                  *
  l(0,1)  l(2,3)    l(4,5)  l(6,7)    l(8,9) l(10,11)  l(12,13) l(14,15)

             *                 *                 .                  .
  * . .    * . .    * * *    . . *    . . *    o . .    . o .     . . o
  * * o  * . * . .  . * .  . . * . *  o * *  . . * . *  . * .   * . * . .
  * . .    . . o    . o .    o . .    . . *    . . *    * * *     * . .
             .                 .                 *                  *
  m(0,1)  m(2,3)    m(4,5)  m(6,7)    m(8,9) m(10,11)  m(12,13) m(14,15)

             o                 o                 .                  .
  o . .    o . .    o o o    . . o    . . o    * . .    . * .     . . *
  o * *  o . * . .  . * .  . . * . o  * * o  . . * . o  . * .   o . * . .
  o . .    . . *    . * .    * . .    . . o    . . o    o o o     o . .
             .                 .                 o                  o
  d(0,1)  d(2,3)    d(4,5)  d(6,7)    d(8,9) d(10,11)  d(12,13) d(14,15)

             *                 *                 o                  o
  * o o    o * o    * o *    o * o    o o *    * . o    o * o     o . *
  o * *  * * * . o  o * o  o . * * *  * * o  o . * * *  o * o   * * * . o
  * o o    o . *    o * o    * . o    o o *    o * o    * o *     o * o
             o                 o                 *                  *
  f(0,1)  f(2,3)    f(4,5)  f(6,7)    f(8,9) f(10,11)  f(12,13) f(14,15)

             *                 o                 o                  *
  * * *    o . *    o o *    o . o    o o o    o . o    * o o     * . o
  o * o  o . * . *  o * *  o . * . *  o * o  * . * . o  * * o   * . * . o
  o o o    o . o    o o *    o . *    * * *    * . o    * o o     o . o
             o                 *                 *                  o
  f2(0,1) f2(2,3)  f2(4,5)  f2(6,7)  f2(8,9) f2(10,11)f2(12,13) f2(14,15)

             *                 .                 .                  o
  * * o    . . *    . . *    . . .    . . .    . . .    o . .     * . .
  . * .  . . * . o  . * *  . . * . *  . * .  o . * . .  * * .   * . * . .
  . . .    . . .    . . o    . . *    o * *    * . .    * . .     . . .
             .                 o                 *                  .
  k(0,1)  k(2,3)    k(4,5)  k(6,7)    k(8,9) k(10,11)  k(12,13) k(14,15)

  * . .      *      * * *      *      . . *      .      . . .       .
  * o .    * . .    . o .    . . *    . o *    . . .    . o .     . . .
  * . .  * . o . .  . . .  . . o . *  . . *  . . o   *  * * *   *   o . .
           . . .             . . .             . . *              * . .
             .                 .                 *                  *
  c(0,1)  c(2,3)    c(4,5)  c(6,7)    c(8,9) c(10,11)  c(12,13) c(14,15)
</span></p>
<h2 id="sec_execution">运行信息</h2>
<ul>
  <li>多线程类型:可重入(与非独占操作符并行运行)。</li>
<li>多线程作用域:全局(可以从任何线程调用)。</li>
  <li>未经并行化处理。</li>
</ul>
<h2 id="sec_parameters">参数表</h2>
  <div class="par">
<div class="parhead">
<span id="StructElement1" class="parname"><b><code><span data-if="hdevelop" style="display:inline">StructElement1</span><span data-if="c" style="display:none">StructElement1</span><span data-if="cpp" style="display:none">StructElement1</span><span data-if="com" style="display:none">StructElement1</span><span data-if="dotnet" style="display:none">structElement1</span><span data-if="python" style="display:none">struct_element_1</span></code></b> (output_object)  </span><span>region <code>→</code> <span data-if="hdevelop" style="display:inline">object</span><span data-if="dotnet" style="display:none"><a href="HRegion.html">HRegion</a></span><span data-if="python" style="display:none">HObject</span><span data-if="cpp" style="display:none"><a href="HRegion.html">HRegion</a></span><span data-if="c" style="display:none">Hobject *</span></span>
</div>
<p class="pardesc">Structuring element for the foreground.</p>
</div>
  <div class="par">
<div class="parhead">
<span id="StructElement2" class="parname"><b><code><span data-if="hdevelop" style="display:inline">StructElement2</span><span data-if="c" style="display:none">StructElement2</span><span data-if="cpp" style="display:none">StructElement2</span><span data-if="com" style="display:none">StructElement2</span><span data-if="dotnet" style="display:none">structElement2</span><span data-if="python" style="display:none">struct_element_2</span></code></b> (output_object)  </span><span>region <code>→</code> <span data-if="hdevelop" style="display:inline">object</span><span data-if="dotnet" style="display:none"><a href="HRegion.html">HRegion</a></span><span data-if="python" style="display:none">HObject</span><span data-if="cpp" style="display:none"><a href="HRegion.html">HRegion</a></span><span data-if="c" style="display:none">Hobject *</span></span>
</div>
<p class="pardesc">Structuring element for the background.</p>
</div>
  <div class="par">
<div class="parhead">
<span id="GolayElement" class="parname"><b><code><span data-if="hdevelop" style="display:inline">GolayElement</span><span data-if="c" style="display:none">GolayElement</span><span data-if="cpp" style="display:none">GolayElement</span><span data-if="com" style="display:none">GolayElement</span><span data-if="dotnet" style="display:none">golayElement</span><span data-if="python" style="display:none">golay_element</span></code></b> (input_control)  </span><span>string <code>→</code> <span data-if="dotnet" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="python" style="display:none">str</span><span data-if="cpp" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="c" style="display:none">Htuple</span><span data-if="hdevelop" style="display:inline"> (string)</span><span data-if="dotnet" style="display:none"> (<i>string</i>)</span><span data-if="cpp" style="display:none"> (<i>HString</i>)</span><span data-if="c" style="display:none"> (<i>char*</i>)</span></span>
</div>
<p class="pardesc">Name of the structuring element.</p>
<p class="pardesc"><span class="parcat">Default:
      </span>
    <span data-if="hdevelop" style="display:inline">'l'</span>
    <span data-if="c" style="display:none">"l"</span>
    <span data-if="cpp" style="display:none">"l"</span>
    <span data-if="com" style="display:none">"l"</span>
    <span data-if="dotnet" style="display:none">"l"</span>
    <span data-if="python" style="display:none">"l"</span>
</p>
<p class="pardesc"><span class="parcat">List of values:
      </span><span data-if="hdevelop" style="display:inline">'c'</span><span data-if="c" style="display:none">"c"</span><span data-if="cpp" style="display:none">"c"</span><span data-if="com" style="display:none">"c"</span><span data-if="dotnet" style="display:none">"c"</span><span data-if="python" style="display:none">"c"</span>, <span data-if="hdevelop" style="display:inline">'d'</span><span data-if="c" style="display:none">"d"</span><span data-if="cpp" style="display:none">"d"</span><span data-if="com" style="display:none">"d"</span><span data-if="dotnet" style="display:none">"d"</span><span data-if="python" style="display:none">"d"</span>, <span data-if="hdevelop" style="display:inline">'e'</span><span data-if="c" style="display:none">"e"</span><span data-if="cpp" style="display:none">"e"</span><span data-if="com" style="display:none">"e"</span><span data-if="dotnet" style="display:none">"e"</span><span data-if="python" style="display:none">"e"</span>, <span data-if="hdevelop" style="display:inline">'f'</span><span data-if="c" style="display:none">"f"</span><span data-if="cpp" style="display:none">"f"</span><span data-if="com" style="display:none">"f"</span><span data-if="dotnet" style="display:none">"f"</span><span data-if="python" style="display:none">"f"</span>, <span data-if="hdevelop" style="display:inline">'f2'</span><span data-if="c" style="display:none">"f2"</span><span data-if="cpp" style="display:none">"f2"</span><span data-if="com" style="display:none">"f2"</span><span data-if="dotnet" style="display:none">"f2"</span><span data-if="python" style="display:none">"f2"</span>, <span data-if="hdevelop" style="display:inline">'h'</span><span data-if="c" style="display:none">"h"</span><span data-if="cpp" style="display:none">"h"</span><span data-if="com" style="display:none">"h"</span><span data-if="dotnet" style="display:none">"h"</span><span data-if="python" style="display:none">"h"</span>, <span data-if="hdevelop" style="display:inline">'i'</span><span data-if="c" style="display:none">"i"</span><span data-if="cpp" style="display:none">"i"</span><span data-if="com" style="display:none">"i"</span><span data-if="dotnet" style="display:none">"i"</span><span data-if="python" style="display:none">"i"</span>, <span data-if="hdevelop" style="display:inline">'k'</span><span data-if="c" style="display:none">"k"</span><span data-if="cpp" style="display:none">"k"</span><span data-if="com" style="display:none">"k"</span><span data-if="dotnet" style="display:none">"k"</span><span data-if="python" style="display:none">"k"</span>, <span data-if="hdevelop" style="display:inline">'l'</span><span data-if="c" style="display:none">"l"</span><span data-if="cpp" style="display:none">"l"</span><span data-if="com" style="display:none">"l"</span><span data-if="dotnet" style="display:none">"l"</span><span data-if="python" style="display:none">"l"</span>, <span data-if="hdevelop" style="display:inline">'m'</span><span data-if="c" style="display:none">"m"</span><span data-if="cpp" style="display:none">"m"</span><span data-if="com" style="display:none">"m"</span><span data-if="dotnet" style="display:none">"m"</span><span data-if="python" style="display:none">"m"</span></p>
</div>
  <div class="par">
<div class="parhead">
<span id="Rotation" class="parname"><b><code><span data-if="hdevelop" style="display:inline">Rotation</span><span data-if="c" style="display:none">Rotation</span><span data-if="cpp" style="display:none">Rotation</span><span data-if="com" style="display:none">Rotation</span><span data-if="dotnet" style="display:none">rotation</span><span data-if="python" style="display:none">rotation</span></code></b> (input_control)  </span><span>integer <code>→</code> <span data-if="dotnet" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="python" style="display:none">int</span><span data-if="cpp" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="c" style="display:none">Htuple</span><span data-if="hdevelop" style="display:inline"> (integer)</span><span data-if="dotnet" style="display:none"> (<i>int</i> / </span><span data-if="dotnet" style="display:none">long)</span><span data-if="cpp" style="display:none"> (<i>Hlong</i>)</span><span data-if="c" style="display:none"> (<i>Hlong</i>)</span></span>
</div>
<p class="pardesc">Rotation of the Golay element. Depending on the
element, not all rotations are valid.</p>
<p class="pardesc"><span class="parcat">Default:
      </span>0</p>
<p class="pardesc"><span class="parcat">List of values:
      </span>0, 2, 4, 6, 8, 10, 12, 14</p>
</div>
  <div class="par">
<div class="parhead">
<span id="Row" class="parname"><b><code><span data-if="hdevelop" style="display:inline">Row</span><span data-if="c" style="display:none">Row</span><span data-if="cpp" style="display:none">Row</span><span data-if="com" style="display:none">Row</span><span data-if="dotnet" style="display:none">row</span><span data-if="python" style="display:none">row</span></code></b> (input_control)  </span><span>point.y <code>→</code> <span data-if="dotnet" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="python" style="display:none">int</span><span data-if="cpp" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="c" style="display:none">Htuple</span><span data-if="hdevelop" style="display:inline"> (integer)</span><span data-if="dotnet" style="display:none"> (<i>int</i> / </span><span data-if="dotnet" style="display:none">long)</span><span data-if="cpp" style="display:none"> (<i>Hlong</i>)</span><span data-if="c" style="display:none"> (<i>Hlong</i>)</span></span>
</div>
<p class="pardesc">Row coordinate of the reference point.</p>
<p class="pardesc"><span class="parcat">Default:
      </span>16</p>
<p class="pardesc"><span class="parcat">Suggested values:
      </span>0, 16, 32, 128, 256</p>
<p class="pardesc"><span class="parcat">Value range:
      </span><code>0
          ≤
        
    <span data-if="hdevelop" style="display:inline">Row</span>
    <span data-if="c" style="display:none">Row</span>
    <span data-if="cpp" style="display:none">Row</span>
    <span data-if="com" style="display:none">Row</span>
    <span data-if="dotnet" style="display:none">row</span>
    <span data-if="python" style="display:none">row</span>
    
          ≤
          511</code> (lin)</p>
<p class="pardesc"><span class="parcat">Minimum increment:
      </span>1</p>
<p class="pardesc"><span class="parcat">Recommended increment:
      </span>1</p>
</div>
  <div class="par">
<div class="parhead">
<span id="Column" class="parname"><b><code><span data-if="hdevelop" style="display:inline">Column</span><span data-if="c" style="display:none">Column</span><span data-if="cpp" style="display:none">Column</span><span data-if="com" style="display:none">Column</span><span data-if="dotnet" style="display:none">column</span><span data-if="python" style="display:none">column</span></code></b> (input_control)  </span><span>point.x <code>→</code> <span data-if="dotnet" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="python" style="display:none">int</span><span data-if="cpp" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="c" style="display:none">Htuple</span><span data-if="hdevelop" style="display:inline"> (integer)</span><span data-if="dotnet" style="display:none"> (<i>int</i> / </span><span data-if="dotnet" style="display:none">long)</span><span data-if="cpp" style="display:none"> (<i>Hlong</i>)</span><span data-if="c" style="display:none"> (<i>Hlong</i>)</span></span>
</div>
<p class="pardesc">Column coordinate of the reference point.</p>
<p class="pardesc"><span class="parcat">Default:
      </span>16</p>
<p class="pardesc"><span class="parcat">Suggested values:
      </span>0, 16, 32, 128, 256</p>
<p class="pardesc"><span class="parcat">Value range:
      </span><code>0
          ≤
        
    <span data-if="hdevelop" style="display:inline">Column</span>
    <span data-if="c" style="display:none">Column</span>
    <span data-if="cpp" style="display:none">Column</span>
    <span data-if="com" style="display:none">Column</span>
    <span data-if="dotnet" style="display:none">column</span>
    <span data-if="python" style="display:none">column</span>
    
          ≤
          511</code> (lin)</p>
<p class="pardesc"><span class="parcat">Minimum increment:
      </span>1</p>
<p class="pardesc"><span class="parcat">Recommended increment:
      </span>1</p>
</div>
<h2 id="sec_result">结果</h2>
<p><code><span data-if="hdevelop" style="display:inline">golay_elements</span><span data-if="c" style="display:none">golay_elements</span><span data-if="cpp" style="display:none">GolayElements</span><span data-if="com" style="display:none">GolayElements</span><span data-if="dotnet" style="display:none">GolayElements</span><span data-if="python" style="display:none">golay_elements</span></code> returns <TT>2</TT> (
      <TT>H_MSG_TRUE</TT>)
     if all parameters are
correct.  Otherwise, an exception is raised.</p>
<h2 id="sec_successors">可能的后置算子</h2>
<p>
<code><a href="hit_or_miss.html"><span data-if="hdevelop" style="display:inline">hit_or_miss</span><span data-if="c" style="display:none">hit_or_miss</span><span data-if="cpp" style="display:none">HitOrMiss</span><span data-if="com" style="display:none">HitOrMiss</span><span data-if="dotnet" style="display:none">HitOrMiss</span><span data-if="python" style="display:none">hit_or_miss</span></a></code>
</p>
<h2 id="sec_alternatives">可替代算子</h2>
<p>
<code><a href="gen_region_points.html"><span data-if="hdevelop" style="display:inline">gen_region_points</span><span data-if="c" style="display:none">gen_region_points</span><span data-if="cpp" style="display:none">GenRegionPoints</span><span data-if="com" style="display:none">GenRegionPoints</span><span data-if="dotnet" style="display:none">GenRegionPoints</span><span data-if="python" style="display:none">gen_region_points</span></a></code>, 
<code><a href="gen_struct_elements.html"><span data-if="hdevelop" style="display:inline">gen_struct_elements</span><span data-if="c" style="display:none">gen_struct_elements</span><span data-if="cpp" style="display:none">GenStructElements</span><span data-if="com" style="display:none">GenStructElements</span><span data-if="dotnet" style="display:none">GenStructElements</span><span data-if="python" style="display:none">gen_struct_elements</span></a></code>, 
<code><a href="gen_region_polygon_filled.html"><span data-if="hdevelop" style="display:inline">gen_region_polygon_filled</span><span data-if="c" style="display:none">gen_region_polygon_filled</span><span data-if="cpp" style="display:none">GenRegionPolygonFilled</span><span data-if="com" style="display:none">GenRegionPolygonFilled</span><span data-if="dotnet" style="display:none">GenRegionPolygonFilled</span><span data-if="python" style="display:none">gen_region_polygon_filled</span></a></code>
</p>
<h2 id="sec_see">参考其它</h2>
<p>
<code><a href="dilation_golay.html"><span data-if="hdevelop" style="display:inline">dilation_golay</span><span data-if="c" style="display:none">dilation_golay</span><span data-if="cpp" style="display:none">DilationGolay</span><span data-if="com" style="display:none">DilationGolay</span><span data-if="dotnet" style="display:none">DilationGolay</span><span data-if="python" style="display:none">dilation_golay</span></a></code>, 
<code><a href="erosion_golay.html"><span data-if="hdevelop" style="display:inline">erosion_golay</span><span data-if="c" style="display:none">erosion_golay</span><span data-if="cpp" style="display:none">ErosionGolay</span><span data-if="com" style="display:none">ErosionGolay</span><span data-if="dotnet" style="display:none">ErosionGolay</span><span data-if="python" style="display:none">erosion_golay</span></a></code>, 
<code><a href="opening_golay.html"><span data-if="hdevelop" style="display:inline">opening_golay</span><span data-if="c" style="display:none">opening_golay</span><span data-if="cpp" style="display:none">OpeningGolay</span><span data-if="com" style="display:none">OpeningGolay</span><span data-if="dotnet" style="display:none">OpeningGolay</span><span data-if="python" style="display:none">opening_golay</span></a></code>, 
<code><a href="closing_golay.html"><span data-if="hdevelop" style="display:inline">closing_golay</span><span data-if="c" style="display:none">closing_golay</span><span data-if="cpp" style="display:none">ClosingGolay</span><span data-if="com" style="display:none">ClosingGolay</span><span data-if="dotnet" style="display:none">ClosingGolay</span><span data-if="python" style="display:none">closing_golay</span></a></code>, 
<code><a href="hit_or_miss_golay.html"><span data-if="hdevelop" style="display:inline">hit_or_miss_golay</span><span data-if="c" style="display:none">hit_or_miss_golay</span><span data-if="cpp" style="display:none">HitOrMissGolay</span><span data-if="com" style="display:none">HitOrMissGolay</span><span data-if="dotnet" style="display:none">HitOrMissGolay</span><span data-if="python" style="display:none">hit_or_miss_golay</span></a></code>, 
<code><a href="thickening_golay.html"><span data-if="hdevelop" style="display:inline">thickening_golay</span><span data-if="c" style="display:none">thickening_golay</span><span data-if="cpp" style="display:none">ThickeningGolay</span><span data-if="com" style="display:none">ThickeningGolay</span><span data-if="dotnet" style="display:none">ThickeningGolay</span><span data-if="python" style="display:none">thickening_golay</span></a></code>
</p>
<h2 id="sec_references">References</h2>
<p>

J. Serra: “Image Analysis and Mathematical Morphology”.  Volume I.
Academic Press, 1982
</p>
<h2 id="sec_module">模块</h2>
<p>
Foundation</p>
<!--OP_REF_FOOTER_START-->
<hr>
<div class="indexlink">
<a href="index_classes.html"><span data-if="dotnet" style="display:none;">类别</span><span data-if="cpp" style="display:none;">类别</span></a><span data-if="dotnet" style="display:none;"> | </span><span data-if="cpp" style="display:none;"> | </span><a href="index_by_name.html">算子列表</a>
</div>
<div class="footer">
<div class="copyright">HALCON算子参考手册 Copyright © 2015-2023 51Halcon</div>
</div>
</div>
</body>
</html>
